<template>
  <div>
    <div class="mingshi_box">
      <div
        class="ketang"
        v-for="(item,index) in mingshiList.educationLIST"
        :key="index"
        @click="teacherdetail(item)"
      >
        <img
          :src="item.cover"
          alt=""
        >
        <div class="ketang_wz">
          <div class="ketang_wz_tit">{{item.name}}</div>
          <div class="ketang_wz_author">
            <div class="ketang_wz_author_name">{{item.title}}</div>
          </div>
          <div class="ketang_wz_class">每周一节生活课</div>
          <div class="ketang_wz_price">
            <div>{{item.click_number}}次学习 | {{item.class_sum}}课时</div>
            <div>
              <div class="ketang_wz_line">¥{{item.preferential_money}}</div>
              <div class="ketang_wz_buy">¥{{item.money}}</div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  props: ['mingshiList'],
  data () {
    return {
    }
  },
  methods: {
    teacherdetail (item) {
      this.$emit('teacherdetail', item)
      // this.$router.push({ name: '/coursedetails', params: { curriculumId: item.curriculum_id } })
    }
  },
  components: {},
  created () {
  }
}
</script>
<style>
.mingshi_box {
  width: calc(100vw * 670 / 750);
  margin: 0 auto;
  /* padding-bottom: 20px; */
}
.ketang {
  margin-bottom: 20px;
}
.ketang img {
  width: calc(100vw * 178 / 750);
  height: calc(100vw * 178 / 750 * 211 / 178);
  border-radius: 4px;
  display: inline-block;
  vertical-align: top;
  margin-right: calc(100vw * 27 / 750);
}
.ketang_wz {
  display: inline-block;
  width: calc(100vw * 445 / 750);
  height: calc(100vw * 178 / 750 * 211 / 178);
  vertical-align: top;
}
.ketang_wz_tit {
  font-family: PingFangSC-Medium;
  font-size: 15px;
  font-weight: bold;
  font-stretch: normal;
  line-height: calc(100vw * 178 / 750 * 36 / 178);
  letter-spacing: 1px;
  color: #333333;
  text-overflow: ellipsis;
  display: -webkit-box;
  /* -webkit-box-orient: vertical; */
  /*! autoprefixer: off */
  -webkit-box-orient: vertical;
  /* autoprefixer: on */
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.ketang_wz_author {
  font-family: PingFangSC-Medium;
  font-size: 14px;
  letter-spacing: 1px;
  color: #999999;
  /* margin: 8px 0px 5px; */
  margin-top: calc(100vw * 178 / 750 * 20 / 178);
  margin-bottom: calc(100vw * 178 / 750 * 28 / 178);
}
.ketang_wz_author_name {
  display: inline-block;
  text-align-last: justify;
  text-align: justify;
  text-justify: distribute-all-lines;
}
.ketang_wz_class {
  font-family: PingFangSC-Regular;
  font-size: 12px;
  letter-spacing: 1px;
  color: #999999;
}
.ketang_wz_price {
  font-family: PingFangSC-Regular;
  font-size: 12px;
  letter-spacing: 1px;
  color: #999999;
  display: flex;
  flex-wrap: nowrap;
  flex-direction: row;
  justify-content: space-between;
  align-content: space-between;
  align-items: center;
}
.ketang_wz_price div {
  display: inline-block;
}
.ketang_wz_line {
  display: inline-block;
  text-decoration: line-through;
}
.ketang_wz_buy {
  width: 45px;
  text-align: right;
  font-size: 14px;
  color: #DA4131;
}
</style>
